<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>

<html>
<head>
<title></title>
</head>

<body>

<%-- Interpret user's locale choice --%>
<c:if test="${param['locale'] != null}">
	<fmt:setLocale value="${param['locale']}" scope="session" />
</c:if>

<%-- Offer locale choice to user --%>
<a href="locale-choice.jsp?locale=en-US">USA</a>
-
<a href="locale-choice.jsp?locale=de-DE">Deutschland</a>
-
<a href="locale-choice.jsp?locale=ja-JP">&#26085;&#26412;</a>

<%-- Use URL rewriting to ensure proper session tracking --%>
<form method="get" action="<c:url value='/locale-choice.jsp' />">
<input type=submit value="Stay in session"></form>

<%-- Test resource bundle --%>
<fmt:setLocale value="zh-TW" scope="session" />
<fmt:bundle basename="com.contour.template.template">
	<fmt:message key="template.contact_us" />
</fmt:bundle>

</body>
</html>
